package com.noahplat.user.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.validation.constraints.NotEmpty;
import java.util.Date;

/**
 * 系统类型表
 *
 * @author 李东
 * @version 1.0.0
 * @Date: 2021/3/1 9:52
 **/

@Data
@Table(name = "sys_type")
public class SysType {

    @Id
    private Long id; //主键Id

    @NotEmpty(message = "系统简写不能为空")
    @Column(name = "sys_type")
    private String sysType; //系统名称不能为空

    @Column(name = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    @NotEmpty(message = "系统版本号不能为空")
    @Column(name = "sys_version")
    private String sysVersion;

    @NotEmpty(message = "系统名称不能为空")
    @Column(name = "sys_name")
    private String sysName;
}
